package entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.web.multipart.MultipartFile;

import java.util.Date;
import java.util.List;

public class Blog {
    /**
    * 博客id
    */
    private Integer bid;

    /**
    * 发布地址
    */
    private String badd;

    /**
    * 发布时间
    */
    @JSONField( format = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date btime;

    /**
    * 发布文字内容
    */
    private String btitle;

    /**
    * 发布图片
    */
    private String bimg;

    /**
    * 点赞数
    */
    private Integer blikes;

    /**
    * 发布人
    */
    private Integer buserid;



    /**
     * 朋友关系
     */
    private Firend firend;

    //辅助图片上传属性
    private MultipartFile file;

    private List<User> likes;

    public List<User> getComment() {
        return comment;
    }

    public void setComment(List<User> comment) {
        this.comment = comment;
    }

    private List<User> comment;


    public List<User> getLikes() {
        return likes;
    }

    public void setLikes(List<User> likes) {
        this.likes = likes;
    }



    public MultipartFile getFile() {
        return file;
    }

    public void setFile(MultipartFile file) {
        this.file = file;
    }

    /**
     * 朋友用户信息
     */
    private User user;
    public User getUser() {
        return user;
    }

    public void setUser(User user) {
        this.user = user;
    }
    public Firend getFirend() {
        return firend;
    }

    public void setFirend(Firend firend) {
        this.firend = firend;
    }

    public Integer getBid() {
        return bid;
    }

    public void setBid(Integer bid) {
        this.bid = bid;
    }

    public String getBadd() {
        return badd;
    }

    public void setBadd(String badd) {
        this.badd = badd;
    }

    public Date getBtime() {
        return btime;
    }

    public void setBtime(Date btime) {
        this.btime = btime;
    }

    public String getBtitle() {
        return btitle;
    }

    public void setBtitle(String btitle) {
        this.btitle = btitle;
    }

    public String getBimg() {
        return bimg;
    }

    public void setBimg(String bimg) {
        this.bimg = bimg;
    }

    public Integer getBlikes() {
        return blikes;
    }

    public void setBlikes(Integer blikes) {
        this.blikes = blikes;
    }

    public Integer getBuserid() {
        return buserid;
    }

    public void setBuserid(Integer buserid) {
        this.buserid = buserid;
    }
}